<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
	</head>
	<body>
		<input type="button" id="btn" value="按钮" style="width: 50px;height: 50px; background: #f00;font-size: 20px;" />
		<script>
			/**
			 * 属性操作
			 * 1. .的
			 * 
			 */
			var btn = document.getElementById("btn");
			btn.onclick = function(){
				//alert(btn.type);
				//获取
				console.log(btn.id);
				console.log(btn.value);
				
				//赋值
				btn.value = '小按钮';
//				btn.type = 'input';

//				console.log(btn.style.font-size);
				console.log(btn.style.fontSize);
				console.log(btn.style['font-size']);
				console.log(btn['id']);
			}
		</script>
	</body>
</html>
